package com.weishi.project.training.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.weishi.project.training.domain.HeartRate;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * 心率Mapper接口
 */
public interface HeartRateMapper extends BaseMapper<HeartRate> {

    /**
     * 查询心率列表
     */
    List<HeartRate> selectHeartRateList(HeartRate heartRate);


    /**
     * 查询心率表平均心率
     */
    Integer getAverageHeartRate(@Param("userId") Integer userId, @Param("trainingDayId") Integer trainingDayId, @Param("groupId") Integer groupId);


    HeartRate selectLastNode(Map<String, Object> params);
}